﻿using System.ComponentModel.DataAnnotations;

namespace Shop.Model.Dto.Admin.Gift;

public class GiftEditDto
{
    /// <summary>
    /// 
    /// </summary>
    public long Id { get; set; }
    
    /// <summary>
    /// 商品ID
    /// </summary>
    [Required(ErrorMessage = "活动商品ID不可为空")]
    public int GoodsId { get; set; }

    /// <summary>
    /// 商品规格ID
    /// </summary>
    [Required(ErrorMessage = "活动规格ID不可为空")]
    public int GoodsSpecId { get; set; }

    /// <summary>
    /// 赠品Id
    /// </summary>
    [Required(ErrorMessage = "赠品Id不可为空")]
    public int GiftId { get; set; }

    /// <summary>
    /// 赠品规格
    /// </summary>
    [Required(ErrorMessage = "赠品规格不可为空")]
    public int GiftSpecId { get; set; }

    /// <summary>
    /// 购买量
    /// </summary>
    [Required(ErrorMessage = "购买量不可为空")]
    public int BuyCount { get; set; }

    /// <summary>
    /// 赠送数量
    /// </summary>
    [Required(ErrorMessage = "赠送数量不可为空")]
    public int GiveCount { get; set; }

    /// <summary>
    /// 是否可以叠加
    /// </summary>
    [Required(ErrorMessage = "是否叠加不可为空")]
    public bool IsSuperposition { get; set; }

    /// <summary>
    /// 是否有赠送数量限制
    /// </summary>
    [Required(ErrorMessage = "是否有赠送数量限制不可为空")]
    public bool IsLimited { get; set; }

    /// <summary>
    /// 赠品总数
    /// </summary>
    public int GiftTotal { get; set; }

    /// <summary>
    /// 活动开始时间
    /// </summary>
    public DateTime? UpTime { get; set; }

    /// <summary>
    /// 活动结束时间
    /// </summary>
    public DateTime? DownTime { get; set; }

    /// <summary>
    /// 是否删除
    /// </summary>
    [Required(ErrorMessage = "是否删除不可为空")]
    public bool IsDel { get; set; }
}